﻿using ASmile.Extend;
using System;
using System.Windows.Forms;

namespace ASmile.Win.Forms
{
    public partial class FrmGridComboxEdit : FrmBaseEdit
    {
        public FrmGridComboxEdit()
        {
            InitializeComponent();
            Init();
        }
        
        public string FixedFormName { set; get; }

        void Init()
        {
            coBoxColAutoSizeMode.Items.Clear();
            var autoMode = Enum.GetNames(typeof(DataGridViewAutoSizeColumnsMode));
            coBoxColAutoSizeMode.Items.AddRange(autoMode);
            coBoxColAutoSizeMode.SelectedIndex = 0;
        }

        private void FrmGridComboxEdit_Load(object sender, EventArgs e)
        {
            if (!FixedFormName.IsEmpty())
            {
                txtFormName.Text = FixedFormName;
                txtFormName.ReadOnly = true;
            }
        }

        private void btnSelForm_Click(object sender, EventArgs e)
        {

        }
    }
}
